#ifndef RETOUR_H
#define RETOUR_H

#include "defs.h"

union Val_T {
	long double ld;
	char c;
	bool b;

	long double *lda;
	bool *ba;
};

struct Var_T {
	string nom;
	int type;
	int scope;
	bool initialisee;
	int array_size;
	int array_index;
	Val_T val;
};

class Retour {
public:
	Retour();
	void setVal(long double ld);
	void setVal(char c);
	void setVal(bool b);
	void setVal(long double *lda);
	void setVal(bool *ba);
	long double getLongDouble();
	char getChar();
	bool getBool();
	long double *getLDArray();
	bool *getBoolArray();
	int code;
	Var_T var;
};

#endif